package com.sc.VenusQueryBeta.contract.vip;

import com.hengjun.kingstar.sdk.base.BasePresenter;
import com.hengjun.kingstar.sdk.base.IBaseFragment;
import com.hengjun.kingstar.sdk.base.IBaseModel;
import com.sc.VenusQueryBeta.model.bean.account.msg.MsgListBean;
import com.sc.VenusQueryBeta.model.bean.login.QueryRegisBean;

import io.reactivex.Observable;

/**
 * 推送的Contract
 * Created by Administrator on 2018/11/4.
 */

public interface MsgContract {
    abstract class   MsgPresenter  extends BasePresenter<IMsgModel,IMsgView> {
        //获取推送信息列表
        public abstract void getMsgline(String serverAddress, String projectName, int serverPortString ,String sendId,String loginPort,String loginUserId);

        //查詢註冊服務器
        public abstract void queryRegisterServerSetting(String id);
    }

    interface IMsgModel extends IBaseModel {

        ////查詢註冊服務器
        Observable<QueryRegisBean> queryRegisterServerSetting(String id);

        //获取推送信息列表
        Observable<MsgListBean> getMsgList(String serverAddress, String projectName, int serverPort,String sendId,String loginPort,String loginUserId);
    }

    interface IMsgView extends IBaseFragment {

        /**
         * 顯示查詢註冊
         * @param queryRegisBean
         */
        void showQueryRegisBeanDataSuccess(QueryRegisBean queryRegisBean);

        //获取推送信息列表
        void showMsgListDataSuccess(MsgListBean msgListBean);

        void showNetworkError(Throwable throwable);

    }
}
